<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>日志管理</title>
    <!-- 公共CSS,JS文件 -->
    <#include "../../admin/common/header.ftl"/>
</head>
<body>
<div class="container-fluid">
    <!-- 左右侧导航 -->
    <div class="row">
        <!-- 右侧导航 -->
        <div class="col-xs-12">
            <div class="panel">
                <div class="panel-heading">日志管理</div>
                <div class="panel-body">
                    <div class="row">
                        <!-- 搜索框 -->
                        <form action="/admin/log/list" method="post">
                            <div class="col-xs-2">
                                <select name="requestType" data-placeholder="选择一个请求类型..." class="chosen-select form-control" tabindex="2">
                                  <option value=""></option>
                                  <option value="GET" <#if (((requestType)!'') == 'GET')>selected="selected"</#if> >GET</option>
                                  <option value="POST" <#if (((requestType)!'') == 'POST')>selected="selected"</#if> >POST</option>
                                  <option value="DELETE" <#if (((requestType)!'') == 'DELETE')>selected="selected"</#if> >DELETE</option>
                                  <option value="PUT" <#if (((requestType)!'') == 'PUT')>selected="selected"</#if> >PUT</option>
                                </select>
                            </div>
                            <div class="col-xs-2">
                                <input type="text" name="startDate" value="${startDate!}" class="form-control form-date" placeholder="开始时间" readonly="readonly">
                            </div>
                            <div class="col-xs-2">
                                <input type="text" name="endDate" value="${endDate!}" class="form-control form-date" placeholder="结束时间" readonly="readonly">
                            </div>
                            <div class="col-xs-2">
                                <button class="btn btn-primary" type="submit">搜索</button>
                            </div>
                        </form>
                    </div>
                    <div id="toolbar" class="toolbox btn-group" style="padding-top:10px; padding-bottom:10px;">
                        <div class="tools-group">
                            <@shiro.hasPermission name="admin:log:delete">
                                <button class="btn btn-danger" onclick="optDelete()"><i class="icon icon-times"></i> 删除</button>
                            </@shiro.hasPermission>
                            <@shiro.hasPermission name="admin:log:export">
                                <button class="btn btn-warning" onclick="optExcel()"><i class="icon icon-file-excel"></i> 导出</button>
                            </@shiro.hasPermission>
                        </div>
                    </div>
                    <table class="table table-hover">
                        <thead>
                            <tr>
                                <th><input type="checkbox" onclick="checkBox('ids',this.checked)"/></th>
                                <th>编号</th>
                                <th>请求地址</th>
                                <th>请求类型</th>
                                <th>创建时间</th>
                                <th>修改时间</th>
                                <#--<th>操作</th>-->
                            </tr>
                        </thead>
                        <tbody>
                        <#if page.list??>
                            <#list page.list as logVo>
                                <tr>
                                    <th><input type="checkbox" class="checked_detect" value="${logVo.id!?c }" name="ids"/></th>
                                    <th>${logVo_index+1!}</th>
                                    <th>${logVo.requestUri!}</th>
                                    <th>${logVo.requestType!}</th>
                                    <th>${logVo.tsInsert!}</th>
                                    <th>${logVo.tsUpdate!}</th>
                                    <#--<th>${logVo.tsUpdate!}</th>-->
                                </tr>
                            </#list>
                        </#if>
                        </tbody>
                    </table>
                    <!-- 分页 start -->
                    <#include "../../admin/common/page.ftl"/>
                    <!-- 分页 end -->
                </div>
            </div>
        </div>
    </div>
<#include "../../admin/common/footer.ftl"/>
</div>
<#--导入logList.js文件-->
<script src="/static/zui/js/log/logList.js"></script>
</body>
</html>